All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class sun.security.x509.AlgIdDSA

java.lang.Object
   |
   +----sun.security.x509.AlgorithmId
           |
           +----sun.security.x509.AlgIdDSA

public final class AlgIdDSA
extends AlgorithmId
implements DSAParams
This class identifies DSS/DSA Algorithm variants, which are distinguished by using different algorithm parameters P, Q, G. It uses the NIST/IETF standard DER encoding. These are used to implement the Digital Signature Standard (DSS), FIPS 186.

NOTE: At this time, DSS/DSA Algorithm IDs must always include these parameters. Use of DSS/DSA in modes where parameters are either implicit (e.g. a default applicable to a site or a larger scope), or are derived from some Certificate Authority's DSS certificate, is not currently supported.


Constructor Index

 o AlgIdDSA()
Default constructor.
 o AlgIdDSA(BigInteger, BigInteger, BigInteger)
Constructs a DSS/DSA Algorithm ID from numeric parameters.
 o AlgIdDSA(byte[])
Construct an AlgIdDSA from an X.509 encoded byte array.
 o AlgIdDSA(byte[], byte[], byte[])
Constructs a DSS/DSA Algorithm ID from unsigned integers that define the algorithm parameters.

Method Index

 o decodeParams()
Parses algorithm parameters P, Q, and G.
 o getG()
Returns the DSS/DSA parameter "G"
 o getName()
Returns "DSA", indicating the Digital Signature Algorithm (DSA) as defined by the Digital Signature Standard (DSS), FIPS 186.
 o getP()
Returns the DSS/DSA parameter "P"
 o getQ()
Returns the DSS/DSA parameter "Q"
 o paramsToString()
Provides a human-readable description of the algorithm parameters.
 o toString()
Returns a string describing the algorithm and its parameters.

Constructors

 o AlgIdDSA
 public AlgIdDSA()
Default constructor. The OID and parameters must be deserialized before this algorithm ID is used.

 o AlgIdDSA
 public AlgIdDSA(byte encodedAlg[]) throws IOException
Construct an AlgIdDSA from an X.509 encoded byte array.

 o AlgIdDSA
 public AlgIdDSA(byte p[],
                 byte q[],
                 byte g[]) throws IOException
Constructs a DSS/DSA Algorithm ID from unsigned integers that define the algorithm parameters. Those integers are encoded as big-endian byte arrays.

Parameters:
p - the DSS/DSA paramter "P"
q - the DSS/DSA paramter "Q"
g - the DSS/DSA paramter "G"
 o AlgIdDSA
 public AlgIdDSA(BigInteger p,
                 BigInteger q,
                 BigInteger g)
Constructs a DSS/DSA Algorithm ID from numeric parameters.

Parameters:
p - the DSS/DSA paramter "P"
q - the DSS/DSA paramter "Q"
g - the DSS/DSA paramter "G"

Methods

 o getP
 public BigInteger getP()
Returns the DSS/DSA parameter "P"

 o getQ
 public BigInteger getQ()
Returns the DSS/DSA parameter "Q"

 o getG
 public BigInteger getG()
Returns the DSS/DSA parameter "G"

 o getName
 public String getName()
Returns "DSA", indicating the Digital Signature Algorithm (DSA) as defined by the Digital Signature Standard (DSS), FIPS 186.

Overrides:
getName in class AlgorithmId
 o decodeParams
 protected void decodeParams() throws IOException
Parses algorithm parameters P, Q, and G. They're found in the "params" member, which never needs to be changed.

Overrides:
decodeParams in class AlgorithmId
 o toString
 public String toString()
Returns a string describing the algorithm and its parameters.

Overrides:
toString in class AlgorithmId
 o paramsToString
 protected String paramsToString()
Provides a human-readable description of the algorithm parameters.

Overrides:
paramsToString in class AlgorithmId

All Packages  Class Hierarchy  This Package  Previous  Next  Index